<template>
  <div class="main">
    <MainBar></MainBar>
    <Container></Container>
  </div>
  <TreeContainer v-show="showTree"></TreeContainer>
</template>

<script setup lang="ts">
// import { ESObjectsManager } from "earthsdk3";
import { ESObjectsManager } from '@sdkSrc/ESObjectManager';
import Container from './package/Container.vue';
import MainBar from './package/MainBar.vue';
import TreeContainer from './package/TreeContainer.vue';
import { onMounted, provide, ref } from 'vue';
import MyESObjectsManager from './scripts/MyESObjectsManager';
const props = withDefaults(defineProps<{ objm: MyESObjectsManager; }>(), {});
provide('objm', props.objm);

const showTree = ref(false);
onMounted(() => {
  props.objm.showTreeChanged.don((val) => {
    showTree.value = val;
  })
});
</script>
<style scoped>
.main {
  width: 100%;
  height: 100%;
}
</style>
